home *** CD-ROM | disk | FTP | other *** search
/ Champak 33 / Volume 33 - JOGO DISK .iso / Games / qbear.swf / scripts / DefineSprite_171 / frame_1 / DoAction.as
Text File  |  2007-01-15  |  628b  |  34 lines

  1. ghostbearX = getProperty("/bear/ghost", _X);
  2. ghostbearY = getProperty("/bear/ghost", _Y);
  3. blutoX = _X;
  4. blutoY = _Y;
  5. if(blutoX >= ghostbearX - "20" and ghostbearX + "20" >= blutoX and blutoY >= ghostbearY - "10" and ghostbearY + "10" >= blutoY)
  6. {
  7.    tellTarget("/ball")
  8.    {
  9.       stop();
  10.    }
  11.    tellTarget("/ball/ball2")
  12.    {
  13.       stop();
  14.    }
  15.    tellTarget("/balla")
  16.    {
  17.       stop();
  18.    }
  19.    tellTarget("/balla/ball2")
  20.    {
  21.       stop();
  22.    }
  23.    tellTarget("/bluto")
  24.    {
  25.       stop();
  26.    }
  27.    tellTarget("/collision")
  28.    {
  29.       gotoAndStop("hit");
  30.       play();
  31.    }
  32.    gotoAndStop(3);
  33. }
  34.